package rldungeon.help.parameters

import net.cyndeline.scalarlib.rldungeon.dgs.ParameterEstimator
import rldungeon.help.CorridorEdge
import scalax.collection.immutable.Graph
import net.cyndeline.scalarlib.rldungeon.dgs.graph.Room

/**
 * Checks how many rooms are in a graph.
 */
class RoomAmountEstimator[V <: Room[V]] extends ParameterEstimator[V, CorridorEdge] {
    def value(graph: Graph[V, CorridorEdge]): Double = graph.nodes.size
}
